package com.xiangsai;

import lombok.Data;
import lombok.ToString;

/**
 * @program: paxos-java-demo
 * @description 提案
 * @author: wzx
 * @create: 2021-07-09 16:11
 **/
@Data
@ToString()
public class Proposal {
    //提案名称
    private String name;
    //提案编号
    private Integer id;
    // 提案内容
    private String value;

    public Proposal(Integer id,String name,String value){
        this.id=id;
        this.name=name;
        this.value=value;
    }

    public Proposal(){
        this(-1,null,null);
    }

    public void copyFromInstance(Proposal proposal)
    {
        this.id=proposal.getId();
        this.name=proposal.getName();
        this.value=proposal.getValue();
    }

}
